package com.xgc.book.bookserver.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.xgc.book.bookserver.bean.BookBean;
import com.xgc.book.bookserver.bean.BookCategoryBean;
import com.xgc.book.bookserver.bean.CategoryBean;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * <p>
 * 图书分类表 Mapper 接口
 * </p>
 *
 * @author wrz
 * @since 2023-11-20
 */
@Mapper
public interface BookCategoryMapper extends BaseMapper<BookCategoryBean> {
    IPage<BookBean> getBookByCategoryId(@Param("page") IPage<BookBean> page, @Param("categoryId") int categoryId);

    List<CategoryBean> getCategoryByBookId(int bookId);
}
